#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
#include<stdlib.h>
 
void print_arr(int arr[], int sz)
{
	int i = 0;
	for (i = 0; i < sz; i++)
	{
		printf("%d ", arr[i]);
	}
}
int cmp_int(const void* e1, const void* e2)
{
	return (*(int*)e1 - *(int*)e2);
}
 
void test2()
{
	int arr[] = { 9,8,7,6,5,4,3,2,1,0 };
	
	int sz = sizeof(arr) / sizeof(arr[0]);
	qsort(arr, sz, sizeof(arr[0]), cmp_int);
	print_arr(arr, sz);
}
 
int main()
{
	test2();
	return 0;
}
 
void qsort(void* base, 
	       size_t num, 
	     size_t width, 
	int(*cmp)(const void* e1, const void* e2)
           );

